<?php
	session_start();
	if ( isset( $_SESSION['auth'] ) )
	{
		$fp = @fsockopen( $_SESSION['ip'], $_SESSION['rport'], $errno, $errstr, 5);
		fwrite( $fp, $_SESSION['auth']." LOGOUT" );
		fclose( $fp );
	}
	session_destroy();
	echo '<html>
<head>
<meta http-equiv="refresh" content="2;URL=login.php">
<title>LU Rcon - Logout</title>
</head>
<body>
<h2 style="text-align: center;">Logged out!</h2>
</body>
</html>';
?>